
#ifndef __EDNN_UTILS_H__
#define __EDNN_UTILS_H__



#include "ednn_def.h"



#define ednn_container_of(ptr, type, member) \
    ((type *)((char *)(ptr) - (unsigned long)(&((type *)0)->member)))

#define ednn_list_entry(node, type, member) \
    ednn_container_of(node, type, member)

#define ednn_list_foreach(pos, head) \
    for (pos = (head)->next; pos != (head); pos = pos->next)



#endif /* __EDNN_UTILS_H__ */
